﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using static ConsoleApp1.Student1;

namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            Student1 student = new Student1();

            student.ABd();



            IData sd = new StduentData();

            sd.GetData();


            ComputerMajor computerMajor = new ComputerMajor();
            computerMajor.Id = 14;
            computerMajor.Name = "林鸿鑫";
            computerMajor.chinese  = 100;
            computerMajor.math  = 100;
            computerMajor.PE  = 100;
            Console.WriteLine("学号：" + computerMajor.Id);
            Console.WriteLine("姓名：" + computerMajor.Name);
            Console.WriteLine("成绩信息如下：");
            computerMajor.Total();
            computerMajor.Avg();










            
                ComputerMajor com1 = new ComputerMajor();
                ICompute compute  = com1 ;       //创建接口的实例
                com1.Id = 24;
                com1.Name  = "kobe";
                com1.math  = 999;
                com1 .Programming = 990;
                com1.Database = 985;
                Console.WriteLine("学号：" + com1 .Id);
                Console.WriteLine("姓名：" + com1 .Name);
                Console.WriteLine("成绩信息如下：");
                com1.Total();
                com1.Avg();
            
        }

        private class StduentData : IData
        {
            void IData.GetData()
            {
                Console.WriteLine("我是闽大英格拉姆!");
            }
        }


    }
}
